package com.jadcon.bedbreakfast.domain;

import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;

import org.apache.commons.lang.builder.ToStringBuilder;

public class Reservation {

	private List<Reservation> reservationList = new ArrayList<Reservation>();
	private int reservationNumber;
	private int totalNumberOfGuests;
	private int roomNumber;
	private Date checkIn;
	private Date checkOut;
	private String guestName;
	private String address1;
	private String city;
	private String state;
	private int zip;
	private String phoneNumber;
	private String email;

	public Reservation() {
	}

	Reservation(int reservationNumber, int roomNumber,
			int totalNumberOfGuests, Date checkIn, Date checkOut,
			String guestName, String address1, String city, String state,
			int zip, String phoneNumber, String email) {
		this.reservationNumber = reservationNumber;
		this.roomNumber = roomNumber;
		this.totalNumberOfGuests = totalNumberOfGuests;
		this.checkIn = checkIn;
		this.checkOut = checkOut;
		this.guestName = guestName;
		this.address1 = address1;
		this.city = city;
		this.state = state;
		this.zip = zip;
		this.phoneNumber = phoneNumber;
		this.email = email;
		

	}

	public Date getCheckIn() {
		return checkIn;
	}
	
	public String getCheckInAsString(){
		SimpleDateFormat sdf = new SimpleDateFormat("MM-dd-yyyy");
		String checkIn = sdf.format(getCheckIn());	
		return checkIn;
	}

	public void setCheckIn(Date checkIn) {
		this.checkIn = checkIn;
	}

	public Date getCheckOut() {
		return checkOut;
	}
	
	public String getCheckOutAsString(){
		SimpleDateFormat sdf = new SimpleDateFormat("MM-dd-yyyy");
		String checkOut = sdf.format(getCheckOut());	
		return checkOut;
	}


	public void setCheckOut(Date checkOut) {
		this.checkOut = checkOut;
	}

	public int getTotalNumberOfGuests() {
		return totalNumberOfGuests;
	}

	public void setTotalNumberOfGuests(int totalNumberOfGuests) {
		this.totalNumberOfGuests = totalNumberOfGuests;
	}

	public int getRoomNumber() {
		return roomNumber;
	}

	public void setRoomNumber(int roomNumber) {
		this.roomNumber = roomNumber;
	}

	public void setReservationList(List<Reservation> reservationList) {
		this.reservationList = reservationList;
	}

	public List<Reservation> getReservationList() {
		return reservationList;
	}

	public String toString() {
		return ToStringBuilder.reflectionToString(this);
	}

	public String getGuestName() {
		return guestName;
	}

	public void setGuestName(String guestName) {
		this.guestName = guestName;
	}

	public String getAddress1() {
		return address1;
	}

	public void setAddress1(String address1) {
		this.address1 = address1;
	}

	public String getCity() {
		return city;
	}

	public void setCity(String city) {
		this.city = city;
	}

	public String getState() {
		return state;
	}

	public void setState(String state) {
		this.state = state;
	}

	public int getZip() {
		return zip;
	}

	public void setZip(int zip) {
		this.zip = zip;
	}

	public String getPhoneNumber() {
		return phoneNumber;
	}

	public void setPhoneNumber(String phoneNumber) {
		this.phoneNumber = phoneNumber;
	}

	public String getEmail() {
		return email;
	}

	public void setEmail(String email) {
		this.email = email;
	}

	public int getReservationNumber() {
		return reservationNumber;
	}

	public void setReservationNumber(int reservationNumber) {
		this.reservationNumber = reservationNumber;
	}


	
	

}
